<%-- 
    Document   : updateuser
    Created on : Dec 20, 2012, 9:57:09 AM
    Author     : ngoc.phan
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>JSP Page</title>
    </head>
    <body>
        <h1>Update User here</h1>
        <table border="1">
            <form:form commandName="updateUsers">
                <c:forEach items="${listUser}" var="users">
                    <tr>
                        <td><input name="userName" type="text" value="<c:out value="${users.userName}"/>"</td>
                        <td><input name="password" type="text" value="<c:out value="${users.password}"/>"</td>
                        <td><input name="userId" type="text" value="<c:out value="${users.userId}"/>"</td>
                        <td><c:out value="${users.role.roleId}" /></td>
                        <td><c:out value="${users.role.roleName}" /></td>
                    </tr>
                </c:forEach>
                <input type="submit" value="Update"/>
            </form:form>
        </table>
    </body>
</html>
